package cn.tedu.cinema.employee.mapper;

import cn.tedu.cinema.employee.pojo.dto.EmployeeQuery;
import cn.tedu.cinema.employee.pojo.entity.Employee;
import cn.tedu.cinema.employee.pojo.vo.EmployeeVO;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/* @Repository表示当前是持久层的一部分,主要职责是进行数据库的操作 */
@Repository
public interface EmployeeMapper {

    void insert(Employee employee);

    List<EmployeeVO> selectEmployee(  @Param("pageNum") int pageNum,
                                      @Param("pageSize") int pageSize,
                                       @Param("employeeQuery") EmployeeQuery employeeQuery);

    void update(Employee employee);

    void deleteById(Long employeeId);
    

    EmployeeVO selectByEmployeeName(String employeeName);

    EmployeeVO selectById(Long id);
}
